<?php
/**
 * User: lie
 * Date: 2020/11/6 18:04
 * description:
 */
    echo "<form action='' method='get'>";
    echo "<input type='text' name='username'>";
    echo "<br>";
    echo "<input type='password' name='pwd'>";
    echo "<input type='submit' value='登录' name='sub'>";
    echo "</form>";
    if ($_GET['username'] == '' || $_GET['pwd'] == ''){
        echo "用户名或密码错误";
    } else {
        if ($_GET['username'] == 'admin' && $_GET['pwd'] == 'admin'){
            echo "欢迎管理员";
        } else {
            echo "游客您好";
        }
    }